package com.jinpin.base.controller;

import com.jinpin.api.module.Product.ProductFeign;
import io.seata.spring.annotation.GlobalTransactional;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {

    @Autowired
    private ProductFeign productFeign;

    @GlobalTransactional
    @GetMapping("/test")
    public String test(){
        String test = productFeign.test();
        return "test";
    }
}
